/*
 *  Copyright (c) 2010-2023
 */
package net.siufung.market.base.uuid.mapper.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;
import lombok.Data;

/**
 * 流水号表 数据实体
 * @author 陈建峰
 * @since 2023-10-09 22:16:17
 * @version 1.0.0
 */
@Data
@TableName("sys_uuid")
public class SysUuid implements Serializable {

    private static final long serialVersionUID = 1711385138270720000L;

    /**
     * 主键id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;


    /**
     * 规则名称
     */
    @TableField("uuid_name")
    @Length(max=32, message="规则名称长度不大于32!")
    @NotBlank(message = "规则名称不能为空!")
    private String uuidName;


    /**
     * 规则编码
     */
    @TableField("uuid_code")
    @Length(max=32, message="规则编码长度不大于32!")
    private String uuidCode;


    /**
     * 默认标识
     */
    @TableField("default_flag")
    @NotNull(message = "默认标识不能为空!")
    private Boolean defaultFlag;


    /**
     * 描述
     */
    @TableField("description")
    @Length(max=255, message="描述长度不大于255!")
    private String description;


    /**
     * 租户
     */
    @TableField("tenant_id")
    private Integer tenantId;


    /**
     * 创建人
     */
    @TableField(value = "created_by", fill = FieldFill.INSERT)
    @Length(max=32, message="创建人长度不大于32!")
    private String createdBy;


    /**
     * 创建时间
     */
    @TableField(value = "created_at", fill = FieldFill.INSERT)
    private LocalDateTime createdAt;


    /**
     * 更新人
     */
    @TableField(value = "updated_by", fill = FieldFill.UPDATE)
    @Length(max=32, message="更新人长度不大于32!")
    private String updatedBy;


    /**
     * 更新时间
     */
    @TableField(value = "updated_at", fill = FieldFill.UPDATE)
    private LocalDateTime updatedAt;


    /**
     * 数据标识
     */
    @TableField(value = "deleted", fill = FieldFill.INSERT)
    private Boolean deleted;

}


